package habitat;


import game.player.Player;

import java.util.Vector;



public class HabitatInfo {

	private int habitatID;


	private Vector<Integer> agentIDs;
	
	private Vector<Integer> agentStrategies;
	
	private Vector<int[]> intmat;
	
	
	public int getHabitatID() {
		return habitatID;
	}

	public void setHabitatID(int habitatID) {
		this.habitatID = habitatID;
	}


	
   public HabitatInfo clone(){
	    	HabitatInfo copiedContainerInfo;
	    	try {
	    		copiedContainerInfo=getClass().newInstance();
			} 
	    	catch (Throwable e) {
				System.err.println("Warning: clone of ContainerInfo failed!");
	            return null;
			}
	    	copiedContainerInfo.setHabitatID(habitatID);
	    	
		    	
	    	return copiedContainerInfo;
	    }
	
	public HabitatInfo(Vector<Integer> playerIDs,Vector<Integer> playerStrgies,Vector<int[]> intmat) {
		agentIDs = playerIDs;
		agentStrategies = playerStrgies;
		this.intmat = intmat;
	}
	

	public void addAgent(Integer agentID,Integer agentStgy){
		agentIDs.add(agentID);
		agentStrategies.add(agentStgy);
	}
	public boolean removeAgent(Player agent){
	   return  (agentIDs.remove(agent));
	}
	
	
	public int getAgentsNumber(){
		return agentIDs.size();
	}

}
